home *** CD-ROM | disk | FTP | other *** search
/ The Trig Explorer / The Trig Explorer.iso / mac / Explorer / RIGHT.dxr / 00001.ls next >
Encoding:
Text File  |  1998-07-22  |  534 b   |  25 lines

  1. on startMovie
  2.   cursor(-1)
  3.   set the keyDownScript to "printPass"
  4.   set the keyUpScript to "numsOnly"
  5.   put " " into field "A1"
  6.   set the textStyle of field "A1" to "bold"
  7.   set the textSize of field "A1" to 24
  8. end
  9.  
  10. on numsOnly
  11.   if (the key = RETURN) or (the key = ENTER) or (the key = TAB) or (the key = "-") or (the keyCode = 76) then
  12.     exit
  13.   end if
  14.   if (the key >= "0") and (the key <= "9") then
  15.     exit
  16.   end if
  17.   if the key = "." then
  18.     exit
  19.   end if
  20.   if the key = BACKSPACE then
  21.     exit
  22.   end if
  23.   dontPassEvent()
  24. end
  25.